12 int sizeN
; //Numero de digitos de N
13 unsigned int d
; //equivalente decimal de n
14 while (cin
.peek() != EOF
){
17 while(cin
.peek() != '\n'){
18 n
[sizeN
] = cin
.get() - 48;
20 cout
<< "Lei: " << n
[sizeN
] << " Size es: " << sizeN
<< endl
;
24 if (sizeN
== 1 && n
[0] == 0)
27 for (int i
= 0; i
< sizeN
; i
++)
29 cout
<< endl
<< "Size is: " << sizeN
<< endl
;
33 for (int i
= 0; i
<sizeN
; i
++){
34 d
+= n
[i
] * ((int)pow(2, (sizeN
- i
)) - 1);